package com.care.service;

import java.util.List;

import javax.annotation.Resource;
import javax.transaction.Transactional;

import org.springframework.stereotype.Service;

import com.care.dao.knowledge.KnowledgeDaoImpl;
import com.care.entity.Doctor;
import com.care.entity.Knowledge;
@Service
@Transactional
public class KnowledgeServiceImpl{
	@Resource
	private KnowledgeDaoImpl impl;	
	/**
	 * 添加
	 * @param knowledge
	 */
	public void AddKnowledgeByDoctor(Knowledge knowledge,Doctor doctor){
		impl.AddKnowledgeByDoctor(knowledge,doctor);		
	}
	/**
	 * 去重
	 * @param knowledge
	 * @return 
	 */
	public boolean UniqueKnowledge(Knowledge knowledge){
		return impl.UniqueKnowledge(knowledge);
	}
	/**
	 * 医护知识分页
	 * @param pageNum
	 * @param pageSize
	 * @return
	 */
	public List<Knowledge> FindKnowledgeByPage(int pageNum,int pageSize){
		return impl.FindKnowledgeByPage(pageNum, pageSize);
		
	}
	/**
	 * 数据总数
	 * @return
	 */
	public int CountKnowledge(){
		return impl.CountKnowledge();
	}
	
	
}